fix: enable terminal session persistence by default#770
Merged
ZacharyZcR merged 1 commit intoMay 17, 2026
Merged
Conversation
9b95e25 to
dd0bfb5
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Terminal session persistence (the ability to reconnect to a running SSH session after a page refresh or network interruption) was opt-in and disabled by default. Most users expect sessions to survive brief disconnections (laptop sleep, page refresh) without losing their running commands.
Changes
Changed the default from opt-in (
=== "true") to opt-out (!== "false") across all 4 files that check theenableTerminalSessionPersistencelocalStorage flag:Terminal.tsx— session attach on connect, session save on disconnectTabContext.tsx— tab state save/restoreUserProfile.tsx— settings toggle initial stateUserProfilePanel.tsx— settings toggle initial stateUsers who explicitly disabled persistence (
localStorage.enableTerminalSessionPersistence = "false") will still have it disabled. New users get persistence enabled automatically.Limitations
This fixes same-device session recovery. Cross-device session sharing (seeing sessions from device A on device B) requires additional work — the session ID is stored in localStorage which is browser-local. A future enhancement could query the backend's detached session list on connect.
Related
Closes Termix-SSH/Support#591